package filedownloader;

import java.io.IOException;
import filedownloader.HttpDownloadUtility;
public class MyClass {
	
  //Test comment: commit/push change from eclipse
  
  //Test comment: pull from repository
	
  //Another commit after clean
	public static final String[] DOTA_ITEMS = {"emptyitembg","blink","blades_of_attack", "broadsword","chainmail","claymore","helm_of_iron_will","javelin","mithril_hammer","platemail","quarterstaff","quelling_blade","ring_of_protection","gauntlets",
        "slippers","mantle","branches","belt_of_strength","boots_of_elves","robe","circlet","ogre_axe","blade_of_alacrity","staff_of_wizardry","ultimate_orb","gloves","lifesteal","ring_of_regen","sobi_mask",
        "boots","gem","cloak","talisman_of_evasion","cheese", "magic_stick","recipe_magic_wand", "magic_wand","ghost","clarity","flask","dust","bottle","ward_observer","ward_sentry","tango","courier","tpscroll",
        "recipe_travel_boots","travel_boots","recipe_phase_boots","phase_boots","demon_edge","eagle","reaver","relic","hyperstone","ring_of_health", "void_stone","mystic_staff","energy_booster","point_booster","vitality_booster",
        "recipe_power_treads","power_treads","recipe_hand_of_midas", "hand_of_midas","recipe_oblivion_staff","oblivion_staff","recipe_pers","pers","recipe_poor_mans_shield","poor_mans_shield","recipe_bracer","bracer",
        "recipe_wraith_band","wraith_band","recipe_null_talisman","null_talisman","recipe_mekansm","mekansm", "recipe_vladmir","vladmir","flying_courier","recipe_buckler","buckler","recipe_ring_of_basilius","ring_of_basilius",
        "recipe_pipe", "pipe","recipe_urn_of_shadows","urn_of_shadows", "recipe_headdress","headdress","recipe_sheepstick","sheepstick","recipe_orchid", "orchid","recipe_cyclone","cyclone","recipe_force_staff","force_staff",
        "recipe_dagon","dagon","recipe_necronomicon","necronomicon","recipe_ultimate_scepter","ultimate_scepter","recipe_refresher","refresher","recipe_assault","assault","recipe_heart","heart","recipe_black_king_bar",
        "black_king_bar","aegis","recipe_shivas_guard","shivas_guard","recipe_bloodstone","bloodstone","recipe_sphere","sphere","recipe_vanguard","vanguard","recipe_blade_mail", "blade_mail", "recipe_soul_booster",
        "soul_booster","recipe_hood_of_defiance","hood_of_defiance","recipe_rapier","rapier","recipe_monkey_king_bar","monkey_king_bar", "recipe_radiance", "radiance","recipe_butterfly","butterfly","recipe_greater_crit",
        "greater_crit","recipe_basher","basher","recipe_bfury","bfury","recipe_manta","manta","recipe_lesser_crit","lesser_crit","recipe_armlet","armlet","invis_sword","recipe_sange_and_yasha","sange_and_yasha","recipe_satanic",
        "satanic","recipe_mjollnir","mjollnir", "recipe_skadi","skadi","recipe_sange","sange", "recipe_helm_of_the_dominator","helm_of_the_dominator","recipe_maelstrom", "maelstrom","recipe_desolator","desolator","recipe_yasha",
        "yasha","recipe_mask_of_madness","mask_of_madness","recipe_diffusal_blade", "diffusal_blade","recipe_ethereal_blade","ethereal_blade","recipe_soul_ring", "soul_ring","recipe_arcane_boots","arcane_boots","orb_of_venom",
        "stout_shield","recipe_invis_sword","recipe_ancient_janggo","ancient_janggo","recipe_medallion_of_courage","medallion_of_courage","smoke_of_deceit","recipe_veil_of_discord", "veil_of_discord","recipe_necronomicon_2",
        "recipe_necronomicon_3", "necronomicon_2","necronomicon_3","recipe_diffusal_blade_2","diffusal_blade_2","recipe_dagon_2","recipe_dagon_3","recipe_dagon_4","recipe_dagon_5","dagon_2","dagon_3","dagon_4","dagon_5", "recipe_rod_of_atos",
        "rod_of_atos","recipe_abyssal_blade", "abyssal_blade", "recipe_heavens_halberd","heavens_halberd","recipe_ring_of_aquila","ring_of_aquila","recipe_tranquil_boots","tranquil_boots"};


	/**
	 * @param args
	 */
	public static void main(String[] args) {
		for(int i=1; i<DOTA_ITEMS.length; i++){
			String fileURL = "http://cdn.dota2.com/apps/dota2/images/items/"+ DOTA_ITEMS[i] + "_lg.png";
			String saveDir = System.getProperty("user.home") + "/Desktop/items";
			try {
				HttpDownloadUtility.downloadFile(fileURL, saveDir);
			} catch (IOException ex) {
				ex.printStackTrace();
			}
		}
		System.out.println(DOTA_ITEMS.length-1);
	}

}
